package org.nanfang.shuiguo01;

public class BoxGirl extends Thread{
    private Box box;
    //女孩的姓名
    public String name;

    public BoxGirl(){
        super();
    }
    public BoxGirl(Box box, String name) {
        this.box = box;
        this.name = name;
    }

    @Override
    public void run() {
        while (true){
            box.take(name);
        }
    }
}
